﻿namespace Digitalmes.Domain.Mes;

/// <summary>
/// 产线信息
/// </summary>
[SugarTable("md_line", "产线信息表")]
public class MdLine : EntityBase
{
    /// <summary>
    /// 产线编号
    /// </summary>
    [NotNull]
    [SugarColumn(ColumnDescription = "产线编号", Length = 32)]
    public string? LineCode { get; set; }

    /// <summary>
    /// 产线名称
    /// </summary>
    [NotNull]
    [SugarColumn(ColumnDescription = "产线名称", Length = 32)]
    public string? LineName { get; set; }

    /// <summary>
    /// 负责人
    /// </summary>
    [SugarColumn(ColumnDescription = "负责人", Length = 32)]
    public string? Principal { get; set; }

    /// <summary>
    /// 工位集合
    /// </summary>
    [Navigate(NavigateType.OneToMany, nameof(MdStation.LineId))]
    public List<MdStation>? Stations { get; set; }
}
